hysop.operator.directional.stretching_diffusion_dir module

@file stretching_dir.py Directional stretching frontend (operator generator).

class hysop.operator.directional.stretching_diffusion_dir.DirectionalStretchingDiffusion(viscosity, **kwds)[source]

Bases: DirectionalStretching

Directional stretching + diffusion using the symbolic code generation framework.

Initialize directional stretching + diffusion operator frontend.

Solves dW/dt = C * f(U,W) + viscosity * laplacian(W) where U is the velocity, W the vorticity and f is one of the following formulation:

CONSERVATIVE FORMULATION: f(U,W) = div( U : W ) MIXED GRADIENT FORMULATION: f(U,W) = (A*grad(U) + (1-A)*grad(U)^T) . W

whererepresents the outer product U:W = (Ui*Wj)ij.

. represents the matrix-vector product.

^T is the transposition operator

U and W are always three dimensional fields. C is scalar or 3d vector-like of symbolic coefficients. A is a scalar symbolic coefficient. viscosity is a scalar. f(U,W) is always directionally splittable.

Parameters:
  • viscosity (scalar) – Value of the diffusion coefficient.

  • kwds – Base class keywords arguments. See hysop.operator.directional.stretching_dir.DirectionalStretching.